﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net.NetworkInformation;
using System.Text;
using System.Threading.Tasks;

namespace Tool.Helper.Dm
{
    public class SysHelper
    {
      
        public static List<string> GetMacs()
        {
            List<string> result = new List<string>();
            NetworkInterface[] networkInterfaces = NetworkInterface.GetAllNetworkInterfaces();
            foreach (NetworkInterface networkInterface in networkInterfaces)
            {
                // 获取网卡接口的物理地址（MAC地址）  
                PhysicalAddress physicalAddress = networkInterface.GetPhysicalAddress();
                result.Add(physicalAddress.ToString());
            }
            return result;
        }
    }
}
